    //
//  FAQ.m
//  BetsAndBrains
//
//  Created by Nelson, Adam M (nelso148) on 4/6/12.
//  Copyright 2012 __MyCompanyName__. All rights reserved.
//

#import "FaqViewController.h"
#import "BetsAndBrainsViewController.h"

@implementation FaqViewController

@synthesize faqView;


// The designated initializer.  Override if you create the controller programmatically and want to perform customization that is not appropriate for viewDidLoad.
/*
- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil {
    self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];
    if (self) {
        // Custom initialization.
    }
    return self;
}
*/

/*
// Implement loadView to create a view hierarchy programmatically, without using a nib.
- (void)loadView {
}
*/


// Implement viewDidLoad to do additional setup after loading the view, typically from a nib.
- (void)viewDidLoad {
	
	/*
	 
	Implementation of loading an external html file
	 
	*/
	//////
	////URL of html to load
	//NSString *fullURL = @"http://www.google.com";
	////create the url object
	//NSURL *url = [NSURL URLWithString:fullURL];
	////create a url-request object to request indicated url
	//NSURLRequest *requestObj = [NSURLRequest requestWithURL:url];
	
	/*
	 
	 Load local html titled "index.html"
	 
	 */
	
	NSURL *localUrl = [NSURL fileURLWithPath:[[NSBundle mainBundle] pathForResource:@"index" ofType:@"html"]isDirectory:NO];
	NSURLRequest *requestObj = [NSURLRequest requestWithURL:localUrl];
	
	//load local html file called "index.html"
	[faqView loadRequest:requestObj];
    [super viewDidLoad];
}

-(IBAction)returnToGame{
	BetsAndBrainsViewController* bb = [[BetsAndBrainsViewController alloc] init];
	[self presentModalViewController:bb animated: TRUE];
}


- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation{
    
    return UIInterfaceOrientationIsLandscape(interfaceOrientation);
	
}

- (void)didReceiveMemoryWarning {
    // Releases the view if it doesn't have a superview.
    [super didReceiveMemoryWarning];
    
    // Release any cached data, images, etc. that aren't in use.
}

- (void)viewDidUnload {
	[super viewDidUnload];
	self.faqView = nil;
    // Release any retained subviews of the main view.
    // e.g. self.myOutlet = nil;
}


- (void)dealloc {
	[super dealloc];
	[faqView autorelease];
}


@end
